import org.apache.catalina.startup.Tomcat;

import java.io.File;

public class WebRunner {


	public static void main(String[] args) throws Exception {

		System.setProperty("resources.config.path", "/Users/creazier.huang/Desktop/config/shell");

		Tomcat tomcat = new Tomcat();


		String baseDir = new File("").getAbsolutePath();

		tomcat.setBaseDir(baseDir + "/website/src/test/resources/tomcat-home");

		tomcat.enableNaming();

		tomcat.addWebapp("/", baseDir + "/website/src/main/webapp");

		tomcat.setPort(8080);
		tomcat.start();
		tomcat.getServer().await();
	}
	//

}
